INCLUDE_DIRECTORIES(${CMAKE_BINARY_DIR}/fortran)
LINK_DIRECTORIES(${CMAKE_BINARY_DIR}/fortran)
FIND_LIBRARY(NETCDF_C_LIBRARY NAMES netcdf libnetcdf)
IF(NOT NETCDF_C_LIBRARY)
  MESSAGE(FATAL_ERROR "Cannot find netCDF C library, needed for netCDF Fortran tests.")
ENDIF()

ADD_SUBDIRECTORY(F77)
ADD_SUBDIRECTORY(F90)

SET(CUR_EXTRA_DIST CMakeLists.txt Makefile.am)
ADD_EXTRA_DIST("${CUR_EXTRA_DIST}")
